<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<%--  <jsp:include page="/include.jsp"/>--%>
<form id="add_form" method="post">
<input type="hidden" name="id" value="${id}">
    <table class="listtable" style="width: 100%;">
        <tr class="row-even">
            <td class="tr_left"><span class="required">*</span>姓名:&nbsp;</td>
            <td class="tr_right">
                <input type="text" name="name" value="${name}" maxlength="200" class="easyui-validatebox"
                       data-options="required:true,missingMessage:'请输入姓名'"/>
            </td>
            <td class="tr_left" rowspan="4" style="vertical-align: bottom;"></td>
            <td class="tr_right" rowspan="4" style="vertical-align: top;">
                <c:choose>
                    <c:when test="${photo != null && photo != ''}">
                        <img id="photoPanel" src="${pageContext.request.contextPath}${photo}" style="width: 150px; max-height: 200px;">
                    </c:when>
                    <c:otherwise>
                        <img id="photoPanel" src="${pageContext.request.contextPath}/images/headpicture/none.png" style="width: 150px; max-height: 200px;">
                    </c:otherwise>
                </c:choose>
            </td>
        </tr>
        <tr>
            <td class="tr_left"><span class="required">*</span>性别:&nbsp;</td>
            <td class="tr_right">
                <label>
                    <input type="radio" name="gender" value="1"  <c:if test="${gender =='' || gender == null || gender == 1}">checked="checked" </c:if>/>男
                </label>
                <label>
                    <input type="radio" name="gender" value="0"  <c:if test="${gender != null && gender != '' && gender == 0}">checked="checked" </c:if>/>女
                </label>
            </td>
        </tr>
        <tr class="row-even">
            <td class="tr_left"><span class="required">*</span>证件类型:&nbsp;</td>
            <td class="tr_right" >
                <label>
                    <input type="radio" name="cardType" value="2" <c:if test="${cardType =='' || cardType == null || cardType == 2}">checked="checked" </c:if>/>军官证
                </label>
                <label>
                    <input type="radio" name="cardType" value="1"   <c:if test="${cardType != null && cardType != '' && cardType == 1}">checked="checked" </c:if>/>身份证
                </label>
                
            </td>
        </tr>
        <tr>
            <td class="tr_left"><span class="required">*</span>证件号码:&nbsp;</td>
            <td class="tr_right">
                <input type="text" name="cardNo" value="${cardNo}" maxlength="200"  class="easyui-validatebox"
                       data-options="required:true,missingMessage:'请输入证件号码'" />
            </td>
        </tr>
        <tr class="row-even">
            <td class="tr_left"><span class="required">*</span>开启定位:&nbsp;</td>
            <td class="tr_right">
                <label>
                    <input type="radio" name="recordPosition" value="1" <c:if test="${recordPosition =='' || recordPosition == null || recordPosition == 1}">checked="checked" </c:if>/>开启
                </label>
                <label>
                    <input type="radio" name="recordPosition" value="0" <c:if test="${recordPosition != null && recordPosition != '' && recordPosition == 0}">checked="checked" </c:if>/>关闭
                </label>
            </td>
            <td class="tr_left"><span class="required">*</span>照片:&nbsp;</td>
            <td class="tr_right">
                <input type="text" name="photo" id="photo" value="/images/headpicture/none.png" maxlength="200" class="easyui-validatebox"
                       data-options="required:true,missingMessage:'请上传照片'" readonly/>
                <input type="button" value="上传" onclick="showFileUpload('photo')">
            </td>
        </tr>
        <tr>
            <td class="tr_left"><span class="required">*</span>单位:&nbsp;</td>
            <td class="tr_right" colspan="3">
                <input type="text" name="company" value="${company}" maxlength="200" style="width: 80%;"
                       class="easyui-validatebox" data-options="required:true,missingMessage:'请输入单位名称'"/>
            </td>
        </tr>
        <%--<tr class="row-even">--%>
            <%--<td class="tr_left"><span class="required">*</span>政务:&nbsp;</td>--%>
            <%--<td class="tr_right">--%>
                <%--<input class="easyui-combobox" name="duties" value="${duties}" data-options="--%>
					<%--valueField: 'value',--%>
					<%--textField: 'label',--%>
                    <%--editable:false,--%>
					<%--data: [{--%>
						<%--label: '长官',--%>
						<%--value: '1'--%>
					<%--},{--%>
						<%--label: '士兵',--%>
						<%--value: '2'--%>
					<%--}],required:true,missingMessage:'请选择政务'" class="easyui-combobox"/>--%>
            <%--</td>--%>
        <%--</tr>--%>
        <tr>
        	  <td class="tr_left"><span class="required">*</span>人员类型:&nbsp;</td>
            <td class="tr_right">
                <input class="easyui-combobox" name="level" value="${level}" data-options="
					url:'${pageContext.request.contextPath}/levelAction!getLevelSelectData.action',
                    valueField:'id',
                    textField:'name',
                    editable:false,
                    required:true,missingMessage:'请选择人员类型'"/>
            </td>
           </tr>
        <%-- <tr style="display:none;">--%>
        <tr>
            <td class="tr_left"><span class="required">*</span>区域:&nbsp;</td>
            <td class="tr_right" colspan="3">
                <input id="cc" class="easyui-combobox" name="regionId" value="${regionId}"data-options="
                valueField:'id',
                textField:'name',
                editable:false,
                url:'${pageContext.request.contextPath}/regionInfoAction!getRegionInfoSelectData.action',
                required:true,missingMessage:'请选择工作区域'"/>
            </td>
        </tr>
    </table>
</form>
